//
//  MSAboutMeController.m
//  美娱
//
//  Created by No.8 on 2019/4/9.
//  Copyright © 2019 No.8. All rights reserved.
//

#import "MSAboutMeController.h"

@interface MSAboutMeController ()
//通用导航栏
{
    CustomNavigationBar *naviagtionBar;
    
}
@end

@implementation MSAboutMeController
/** Nav实现 */
- (int)navBarBottom {
    if ([WRNavigationBar isIphoneX]) {
        return 88;
    } else {
        return 64;
    }
}

- (void)viewWillAppear:(BOOL)animated {
    [super viewWillAppear:YES];
    self.navigationController.navigationBar.hidden = YES;
}

- (void)viewWillDisappear:(BOOL)animated {
    [super viewWillDisappear:YES];
    self.navigationController.navigationBar.hidden = YES;
}
- (void)viewDidLoad {
    [super viewDidLoad];
    
    [self createNavigationBar];
    
    
    [self CreatView];
    
    
}


- (void)CreatView{
    
    
    /** 日历按钮*/
    UIImageView * photoIMG = [[UIImageView alloc] initWithFrame:CGRectMake(ScreenWidth / 2 - 120 * px, [self navBarBottom] + 200 * px, 240 * px, 240 * px)];
    photoIMG.image = [UIImage imageNamed:@"aboutme_icon"];
    [self.view addSubview:photoIMG];
    
    
    /** title*/
    UILabel * titleLabel = [[UILabel alloc] initWithFrame:CGRectMake(photoIMG.x, CGRectGetMaxY(photoIMG.frame) + 20 * px, photoIMG.width, 80 * px)];
    titleLabel.textColor = [UIColor whiteColor];
    titleLabel.text = @"美娱";
    titleLabel.textAlignment = NSTextAlignmentCenter;
    titleLabel.font = [UIFont boldSystemFontOfSize:SYRealValue(44 / 2)];
    [self.view addSubview:titleLabel];
    
    /** content*/
    UILabel * contentLabel = [[UILabel alloc] initWithFrame:CGRectMake(60 * px, CGRectGetMaxY(photoIMG.frame)+ 200 * px, ScreenWidth - 120 * px, 400 * px)];
    contentLabel.textColor = [UIColor grayColor];
    contentLabel.numberOfLines  = 0;
    contentLabel.text = @"美娱APP是一款针对KTV，酒吧等经营场所开发的一款员工、房间、营业数据管理系统。根据员工职位登录可展示不同的权限及功能。总经理可以直观实时的查看员工的考勤数据，房间的使用情况，营业收入数据等；员工可使用定位考勤打卡功能；职能部门可进行厨品的出入库操作、房间的管理操作。美娱APP从各个角色出发，为企业量身定制，使企业的管理更高效、更便捷。";
    contentLabel.textAlignment = NSTextAlignmentLeft;
    contentLabel.font = [UIFont systemFontOfSize:SYRealValue(28 / 2)];
    [self.view addSubview:contentLabel];
    
    
    
    /** 版本版权*/
    UILabel * copyrightLabel = [[UILabel alloc] initWithFrame:CGRectMake(ScreenWidth / 3, ScreenHeight - 200 * px, ScreenWidth / 3, 200 * px)];
    copyrightLabel.textColor = BackViewColor;
    copyrightLabel.numberOfLines = 0;
    copyrightLabel.text = @"Copyright2019-2022\n美娱科技版权所有";
    copyrightLabel.textAlignment = NSTextAlignmentCenter;
    copyrightLabel.font = [UIFont systemFontOfSize:SYRealValue(25 / 2)];
    [self.view addSubview:copyrightLabel];
    
}

- (void)createNavigationBar{
    
    self.view.backgroundColor = backgroundcolor;
    naviagtionBar = [[CustomNavigationBar alloc] initWithFrame:CGRectMake(0, 0, ScreenWidth, [self navBarBottom])];
    [self.view addSubview:naviagtionBar];
    naviagtionBar.titleLabel.text = @"关于我们";
    naviagtionBar.rightBtn.hidden = YES;
    naviagtionBar.rightBtnTitle.hidden = YES;
    [self.view addSubview:naviagtionBar];
    
    [naviagtionBar.leftBtn setImage:[UIImage imageNamed:@"左箭头"] forState:UIControlStateNormal];
    [naviagtionBar.leftBtn addTarget:self action:@selector(backClick) forControlEvents:UIControlEventTouchUpInside];
    
}
- (void)backClick{
    
    [self.navigationController popViewControllerAnimated:NO];
}

@end
